package tt.lab.designparttern.factorymethod;

public class Factory {
	public static Product produce(int type) {
		switch (type) {
		case 1:
			return new ProductA();
		case 2:
			return new ProductB();
		default:
			return null;
		}
	}
}
